﻿/*
* Copyright (c) 2010-2012 Tesla Engine Group
* 
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
* 
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
* 
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/

namespace Tesla.Core {
    /// <summary>
    /// Enumeration for engine-defined values.
    /// </summary>
    public enum EngineValue {
        /// <summary>
        /// World matrix to transform vertices in model space to world space.
        /// </summary>
        WorldMatrix,

        /// <summary>
        /// View matrix to transform vertices in world space to view space.
        /// </summary>
        ViewMatrix,

        /// <summary>
        /// Projection matrix to transform vertices in view space to clip/projection space.
        /// </summary>
        ProjectionMatrix,

        /// <summary>
        /// Concatenated World-View matrix.
        /// </summary>
        WorldViewMatrix,

        /// <summary>
        /// Concatenated View-Projection matrix
        /// </summary>
        ViewProjectionMatrix,

        /// <summary>
        /// Concatenated World-View-Projection matrix.
        /// </summary>
        WorldViewProjection,

        /// <summary>
        /// Transpose of the World Inverse matrix. Used to correctly transform normals of geometry with
        /// non-uniform scaling for lighting.
        /// </summary>
        WorldInverseTranspose,

        /// <summary>
        /// Inverse of the world matrix, which takes a vertex from world space back to model space.
        /// </summary>
        WorldMatrixInverse,

        /// <summary>
        /// Inverse of the view matrix, which takes a vertex from view space to world space.
        /// </summary>
        ViewMatrixInverse,

        /// <summary>
        /// Inverse of the view matrix, which takes a vertex from projection space to view space.
        /// </summary>
        ProjectionMatrixInverse,

        /// <summary>
        /// Dimensions of the currently active viewport, represented by a Vector4. X = Viewport.X,
        /// Y = Viewport.U, Z = Viewport.Width, W = Viewport.Height.
        /// </summary>
        Viewport,

        /// <summary>
        /// Resolution of the viewport, represented by a Vector2. X = Width, Y = Height.
        /// </summary>
        Resolution,
        
        /// <summary>
        /// Near and Far values of the view frustum of the currently active camera,
        /// represented by a Vector2. X = Near, Y = Far.
        /// </summary>
        FrustumNearFar,

        /// <summary>
        /// Aspect ratio, float value equal to Width/Height of the currently active camera's
        /// viewport. (float)
        /// </summary>
        AspectRatio,

        /// <summary>
        /// Position of the currently active camera in world space. (Vector3)
        /// </summary>
        CameraPosition,

        /// <summary>
        /// Direction (Forward) of the currently active camera. (Vector3)
        /// </summary>
        CameraDirection,

        /// <summary>
        /// Right vector of the currently active camera. (Vector3)
        /// </summary>
        CameraRight,

        /// <summary>
        /// Up vector of the currently active camera. (Vector3)
        /// </summary>
        CameraUp,

        /// <summary>
        /// Total time in seconds since the application was started (or since the game timer was set). (float)
        /// </summary>
        Time,

        /// <summary>
        /// Time in seconds since the last frame was rendered. (float)
        /// </summary>
        TimePerFrame,

        /// <summary>
        /// Frames per second, which is the inverse of time per frame. (float)
        /// </summary>
        FrameRate,

        /// <summary>
        /// Next random float from the engine's random value stream, between 0.0f and 1.0f.
        /// </summary>
        RandomFloat,

        /// <summary>
        /// Next random int from the engine's random value stream.
        /// </summary>
        RandomInt
    }
}
